Skip to content

Conversation

@feeblefakie
Copy link
Contributor

This is an automated request for a manual backport of the following:

  1. Resolve any conflicts that occur during the cherry-picking process.
git fetch origin &&
git checkout 3.15-pull-3092 &&
git cherry-pick --no-rerere-autoupdate -m1 024172e8a650f26bfc3019642932e0d3424c303b
  1. Push the changes.
  2. Merge this PR after all checks have passed.

Thank you!

@KodaiD KodaiD marked this pull request as ready for review October 30, 2025 10:52
@KodaiD KodaiD requested a review from Copilot October 30, 2025 10:52
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds validation to prevent dropping namespaces that contain non-ScalarDB managed tables (tables without metadata). When attempting to drop such namespaces, an IllegalArgumentException is thrown with an informative error message.

  • Added getTableNamesInNamespaceSql() method to RDB engine strategies to query raw table names
  • Modified dropNamespace() in JdbcAdmin and CosmosAdmin to check for non-ScalarDB tables before dropping
  • Added test utilities (deleteMetadata() and dropTable() methods) to support testing this scenario

Reviewed Changes

Copilot reviewed 26 out of 26 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
AdminTestUtils.java Added abstract methods deleteMetadata() and dropTable() to test utility base class
DistributedStorageAdminIntegrationTestBase.java Added integration test for dropping namespaces with non-ScalarDB managed tables
JdbcAdmin.java Added validation to check for non-ScalarDB tables before dropping namespace
CosmosAdmin.java Added validation to check for non-ScalarDB tables before dropping namespace
RdbEngine*.java Implemented getTableNamesInNamespaceSql() for each database engine
CoreError.java Added error message constant for namespace with non-ScalarDB tables
*AdminTestUtils.java Implemented deleteMetadata() and dropTable() methods for all storage adapters
*AdminIntegrationTest.java Wired up getAdminTestUtils() and disabled test for SQLite/DynamoDB

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@KodaiD KodaiD merged commit 4e220e4 into 3.15 Oct 30, 2025
104 of 105 checks passed
@KodaiD KodaiD deleted the 3.15-pull-3092 branch October 30, 2025 11:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants